package com.fingerth.demo.bean.base;

import java.util.ArrayList;
import java.util.List;

public class BaseResListBean<T> extends BaseBean {
    public BaseResData<T> data;
    public static class BaseResData<T>{
        public int count;
        public int totalPage;
        public List<T> list;
    }

    public BaseResListBean() {
        this.data = new BaseResData<>();
        this.data.list = new ArrayList<>();
    }

    public void addData(BaseResData<T> data) {
        this.data.count = data.count;
        this.data.totalPage = data.totalPage;
        this.data.list.addAll(data.list);
    }


    public void clear() {
        this.data.list.clear();
    }
}
